"""rename fields

Revision ID: efd4c7ee4080
Revises: 525999fd6d93
Create Date: 2024-05-23 19:34:54.720983

"""
from typing import Sequence, Union

from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision: str = 'efd4c7ee4080'
down_revision: Union[str, None] = '525999fd6d93'
branch_labels: Union[str, Sequence[str], None] = None
depends_on: Union[str, Sequence[str], None] = None


def upgrade() -> None:
    # ### commands auto generated by Alembic - please adjust! ###
    op.add_column('salaries', sa.Column('salary_amount', sa.Integer(), nullable=True))
    op.add_column('salaries', sa.Column('next_raise_date', sa.Date(), nullable=True))
    op.drop_column('salaries', 'date')
    op.drop_column('salaries', 'amount')
    # ### end Alembic commands ###


def downgrade() -> None:
    # ### commands auto generated by Alembic - please adjust! ###
    op.add_column('salaries', sa.Column('amount', sa.INTEGER(), autoincrement=False, nullable=False))
    op.add_column('salaries', sa.Column('date', sa.DATE(), autoincrement=False, nullable=False))
    op.drop_column('salaries', 'next_raise_date')
    op.drop_column('salaries', 'salary_amount')
    # ### end Alembic commands ###
